﻿@model Web.ViewModel.HotelDetails

<div class="modal fade" id="hotel-modal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                <h4 class="modal-title" id="myModalLabel">Hotel: @Model.Name</h4>
            </div>
            <div class="modal-body">
                <div>
                    <strong>Opis: </strong>
                    <p>@Model.Description</p>
                </div>
                <div>
                    <strong>Mapa obiektu: </strong>
                    <div id="googleMap" style="width:500px;height:380px;"></div>
                </div>
               
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-default" data-dismiss="modal">Zamknij</button>
            </div>
        </div>
    </div>
</div>


<script src="http://maps.googleapis.com/maps/api/js"></script>
    <script>
        function initialize() {
            
        }
        var mapProp = {
            center: new google.maps.LatLng(@Model.Latitude , @Model.Longitude),
            zoom: 5,
            mapTypeId: google.maps.MapTypeId.ROADMAP
        };
        $(document).ready(function () {
          
            var map = new google.maps.Map(document.getElementById("googleMap"), mapProp);
            google.maps.event.addDomListener(window, 'load', initialize);
           
           
        });
    </script>